<div class="container-fluid">
    <div class="row">
        <div class="col-md-8">
            <div class="panel panel-success">
                <div class="panel-body">
                     <form action="" method="post" novalidate>
                        {% csrf_token %}
                        {% for foo in form %}
                            <div class="form-group">
                                <div><label for="">{{ foo.label }}</label></div>
                                {% if foo.is_pop %}
                                    {{ foo }}
                                    <a href="" onclick="pop('{{ foo.url }}')">+</a>
                                {% else %}
                                    {{ foo }}
                                {% endif %}
                                <span>{{ foo.errors.0 }}</span>
                            </div>
                        {% endfor %}
                        <button type="submit" class=" btn btn-success">提交</button>
                    </form>
                </div>
            </div>
        </div>
    </div>


</div>
<script>
    function pop(url) {
        window.open(url, "", "width=600,height=300")
    }
    $("input").addClass("form-control");
    $("select").addClass("form-control");
</script>